import Vue from 'vue'
import VueRouter from 'vue-router'
import HomeView from '../views/HomeView.vue'
import index from '../views/Index.vue'

Vue.use(VueRouter)

const routes = [

  {
    path: '/yysj',
    name: '预约试驾',
    component: () => import('../views/yysj.vue'),
  },
  
  {
    path: '/wdcx',
    name: '网点查询',
    component: () => import('../views/Wangdian.vue'),
  },
  {
    path: '/index',
    name: '首页',
    component: () => import('../views/Index.vue'),
  },
  {
    path: '/zxdc',
    name: '在线订车',
    component: () => import('../views/zxdc.vue'),
  },
  {
    path:'/lxwm',
    name:'联系我们',
    component:()=>import('../views/CantactUs.vue'),
    meta:{
      title:'联系我们',
    },
  },
  {
    path: '/',
    name: '首页',
    component: index
  },
  {
    path: '/register',
    name: '注册',
    component: () => import('../views/Register.vue'),
  },
  {
    path: '/login',
    name: '登录',
    component: () => import('../views/Login.vue')
  },
  // {
  //   path: '/',
  //   name: '首页',
  //   component: HomeView
  // },
  {
    path: '/about',
    name: 'about',
    component: () => import(/* webpackChunkName: "about" */ '../views/AboutView.vue')
  }
]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
